<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
  <script src="js/vue.js"></script>
</head>
<body>
<div id = "app">
  <p>{{num}}</p>
  <input type="button" value="+" @click="add">
  <input type="button" value="-" @click="sub">
</div>
<script>
    Vue.createApp({

    data(){
    return{
    num:0
    }},
    methods:{
    add(){
    this.num++
    },
    sub(){
    this.num--
    }
    }
    }).mount('#app')
</script>
</body>
</html>